/**
 * Copyright (c) 2018-2022, NXOS Development Team
 * SPDX-License-Identifier: Apache-2.0
 * 
 * Contains: Hook system
 * 
 * Change Logs:
 * Date           Author            Notes
 * 2022-10-10     JasonHu           Init
 */

#include <base/hooks.h>

#ifdef NX_MAIN_THREAD_HOOK
NX_WEAK_SYM void NX_MainThreadHook(void) {}
#endif

#ifdef NX_STARTUP_HOOK
NX_WEAK_SYM void NX_StartupHook(void) {}
#endif

#ifdef NX_CORE_STARTUP_HOOK
NX_WEAK_SYM void NX_CoreStartupHook(NX_UArch coreId) {}
#endif

#ifdef NX_TICKS_HOOK
NX_WEAK_SYM void NX_TicksHook(void) {}
#endif

#ifdef NX_IDLE_HOOK
NX_WEAK_SYM void NX_IdleHook(void) {}
#endif

#ifdef NX_CONTEXT_SWITCH_HOOK
NX_WEAK_SYM void NX_ContextSwitchHook(NX_Thread * prev, NX_Thread * next) {}
#endif

#ifdef NX_PREV_THREAD_HOOK
NX_WEAK_SYM void NX_PrevThreadHook(NX_Thread * thread) {}
#endif

#ifdef NX_POST_THREAD_HOOK
NX_WEAK_SYM void NX_PostThreadHook(NX_Thread * thread) {}
#endif

#ifdef NX_SYSCALL_ENTER_HOOK
NX_WEAK_SYM void NX_SyscallEnterHook(NX_SyscallApi api, NX_UArch arg0, NX_UArch arg1, NX_UArch arg2,
        NX_UArch arg3, NX_UArch arg4, NX_UArch arg5, NX_UArch arg6) {}
#endif

#ifdef NX_SYSCALL_LEAVE_HOOK
NX_WEAK_SYM void NX_SyscallLeaveHook(NX_SyscallApi api, NX_UArch retval) {}
#endif
